/*
 * Copyright (c) dabing.io
 * All rights reserved.
 * JobsConfiguration.java
 */

package com.ueboot.weishop.admin.batch;

import com.ueboot.weishop.admin.batch.jobs.JobSettleConfiguration;
import org.springframework.batch.core.configuration.annotation.EnableBatchProcessing;
import org.springframework.batch.core.configuration.support.ApplicationContextFactory;
import org.springframework.batch.core.configuration.support.GenericApplicationContextFactory;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * 描述: 注册所有Jobs 供给JobLauncher执行使用
 *
 * @author Yvan
 * @since 1.0
 */
@Configuration
@EnableBatchProcessing(modular=true)
public class JobsConfiguration {

    @Bean
    public ApplicationContextFactory jobSettle(){
        return new GenericApplicationContextFactory(JobSettleConfiguration.class);
    }
}